package com.itheima.grow.controller;

import com.itheima.grow.model.info.OssFileInfo;
import com.itheima.grow.model.other.Result;
import com.itheima.grow.util.DateUtil;
import com.itheima.grow.util.SendSmsUtil;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Slf4j
@RestController
@RequestMapping("/sms")
public class SmsController {

    @GetMapping("/send")
    public Result send() {
        System.out.println("==============================");
        int i=0;
        if(i==2){
            SendSmsUtil.sendSMS();
        }else {
            log.info("没有权限执行！");
        }
        int currentDay = DateUtil.getCurrentDay();
        if(1==3){
            System.out.println("-------");
        }else {

        }
        return Result.success();
    }
}
